package com.duying.gh.dao;

import java.util.Date;

import com.busi.framework.base.BaseDao;
import com.busi.utils.tools.DateTools;
import com.duying.gh.GhCC;
import com.duying.gh.model.Hj;
import com.duying.gh.model.People;
import com.duying.gh.model.Unit;

public class HjDao  extends BaseDao{
	public Class getEntityClass(){
		return Hj.class;
	}
	
	public void saveNewHj(People p , Unit u , String curUser){
		Date curDate = DateTools.getCurDate();
		Hj hj = new Hj();
		hj.setAdd_date(curDate);
		hj.setAdd_user(curUser);
		hj.setChg_date(curDate);
		hj.setChg_type(GhCC.hj_zr);
		hj.setChg_reason(GhCC.hj_zr_xjgh);
		hj.setPeople(p);
		hj.setToUnit(u);
		this.saveOrUpdateLog(hj);
	}

}
